Skip to content

feat: 온도 그래프 수정 및 자녀 화면 사이드바/건강기록 구현 #143

Merged
taekoong merged 10 commits intomainfrom
fe/fix/develop
Aug 18, 2025
Merged

feat: 온도 그래프 수정 및 자녀 화면 사이드바/건강기록 구현 #143
taekoong merged 10 commits intomainfrom
fe/fix/develop

Conversation

@taekoong
Copy link
Collaborator

@taekoong taekoong commented Aug 18, 2025

Summary by CodeRabbit

  • 신기능
    • 홈 대시보드가 가족 컨텍스트를 인식해 자녀/보호자별 알약·통증·걸음 정보를 맞춤 표시하고, 앱 복귀 시 빠른 갱신을 수행합니다.
    • 알약 추가 후 이전 화면으로 돌아가 성공 처리 후 안내 팝업을 표시합니다.
    • 알약 기록 화면에 오늘 남은 복용 횟수 표시 및 즉시/낙관적 갱신을 도입했습니다.
    • 운동 카드 문구가 자녀 여부에 따라 동적으로 변경됩니다.
    • 통증 영역 문구 줄바꿈 및 자녀용 사용자 선택 드롭다운 가독성과 레이아웃을 개선했습니다.
    • 그래프 Y축 라벨 간격·크기·여백을 조정해 가독성을 높였습니다.
    • 사진 상세 화면에 SVG 뒤로가기 버튼 적용, 상단 버튼 정리 및 여백 조정.

@coderabbitai
Copy link

coderabbitai bot commented Aug 18, 2025

Walkthrough

여러 화면에서 UI와 플로우가 수정되었습니다. 약 추가 후의 네비게이션 및 팝업 표시 방식이 변경되었고, 약 기록 화면은 남은 복용 횟수 계산과 낙관적 업데이트를 도입했습니다. 홈 대시보드는 가족/자녀 컨텍스트를 인지하도록 로직이 확장되었으며, 일부 텍스트/스타일과 그래프 축 라벨링, 사진 상세의 뒤로가기 UI가 조정되었습니다.

Changes

Cohort / File(s) Summary
Pill add flow & history logic
frontend/ongi/lib/screens/health/add_pill_screen.dart, frontend/ongi/lib/screens/health/pill_history_screen.dart
약 추가 후 pushReplacement → pop(result:true)로 변경하고, 100ms 지연 뒤 Dialog로 PillUpdatePopup 표시. 약 기록 화면에 _todayPillCount 추가, 오늘 남은 복용 횟수 계산/표시, AddPill 결과 true일 때만 즉시 재조회, 추가/삭제 시 낙관적 카운트 업데이트 및 실패 시 롤백.
Health home UI tweaks
frontend/ongi/lib/screens/health/health_home_screen.dart
통증 문구에 줄바꿈 추가. 자녀용 드롭다운을 Flexible 래핑, 패딩/아이템 높이/텍스트 라인높이/ellipsis 등으로 클리핑 개선, 정렬 및 간격 조정.
Exercise label change
frontend/ongi/lib/screens/health/exercise_record_screen.dart
상단 텍스트를 isChild 상태에 따라 ‘다 채우셨을까요?’/‘다 채우셨나요?’로 동적 표시. 주석 공백 수정.
Home graph axis tuning
frontend/ongi/lib/screens/home/home_degree_graph.dart
horizontalInterval 계산 보완(범위 0 처리, 10 라벨 목표 주석). Y축 라벨 경계 근접값 필터, 글꼴 크기/예약 영역 조정, 범위 밖 값 제외.
Home dashboard family-awareness
frontend/ongi/lib/screens/home/home_donutCapsule.dart
자녀/부모 분기 도입. 자녀일 때 가족 정보/부모별 스케줄 조회, 최근 복용 예정 계산, 통증/걸음 집계. 앱 재개 시 알약 데이터 새로고침, 타임아웃/예외 처리 및 기본 문구 정비.
Photo detail back UI
frontend/ongi/lib/screens/photo/detail_record_screen.dart
flutter_svg 도입. 뒤로가기 버튼을 GestureDetector+SVG 아이콘으로 교체, 우상단 공유/메뉴 제거, 상단 패딩 조정.

Sequence Diagram(s)

sequenceDiagram
  actor User
  participant AddPill as AddPillScreen
  participant Prev as PreviousScreen
  participant UI as Dialog

  User->>AddPill: 약 정보 제출
  AddPill-->>Prev: Navigator.pop(context, true)
  Note right of Prev: 결과 true 수신
  Prev->>Prev: (옵션) 상태 갱신/재조회
  Prev-->>UI: 100ms 지연 후 PillUpdatePopup 표시
Loading
sequenceDiagram
  actor User
  participant History as PillHistoryScreen
  participant Svc as Server

  History->>Svc: 오늘 스케줄 조회
  Svc-->>History: intakeTimes, dayIntakeStatus
  History->>History: 남은 복용(_todayPillCount) 계산

  User->>History: 복용 추가
  History->>History: _todayPillCount-- (낙관적)
  History->>Svc: 기록 추가
  alt 실패
    History->>History: _todayPillCount++ (롤백)
  end

  User->>History: 복용 삭제
  History->>History: _todayPillCount++
  History->>Svc: 기록 삭제
  alt 실패
    History->>History: _todayPillCount--
  end
Loading
sequenceDiagram
  actor User
  participant Home as HomeDonutCapsule
  participant Prefs as PrefsManager
  participant Fam as FamilyService
  participant API as Server APIs

  User->>Home: 화면 진입/앱 재개
  Home->>Prefs: isParent 조회
  alt 자녀
    Home->>Fam: 가족 구성원 조회
    loop 부모별
      Home->>API: 알약 스케줄 조회 (타임아웃 5s)
      API-->>Home: 스케줄
      Home->>Home: 최근 예정 복용 계산
    end
    Home->>Home: 통증/걸음 집계 및 문구 구성
  else 부모
    Home->>API: 개인 데이터 조회
    Home->>Home: 기존 로직으로 문구 구성
  end
  Home-->>User: 대시보드 갱신
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~60 minutes

Poem

(•̀ᴗ•́)و ̑̑ 토끼가 깡총, 코드 숲을 달려가요!
팝업은 살짝 늦게, 결과는 먼저 전해요.
남은 약도 착! 착! 숫자로 챙겨두고,
가족 소식 모아 홈에 살포시 놓아요.
그래프도 가지런, 뒤로가긴 똑딱!
오늘 배포, 당근 케이크로 축하해요 🥕✨

Tip

🔌 Remote MCP (Model Context Protocol) integration is now available!

Pro plan users can now connect to remote MCP servers from the Integrations page. Connect with popular remote MCPs such as Notion and Linear to add more context to your reviews and chats.


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Free

💡 Knowledge Base configuration:

  • Jira integration is disabled
  • Linear integration is disabled

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 44c0648 and 3f2d6c7.

📒 Files selected for processing (7)
  • frontend/ongi/lib/screens/health/add_pill_screen.dart (1 hunks)
  • frontend/ongi/lib/screens/health/exercise_record_screen.dart (2 hunks)
  • frontend/ongi/lib/screens/health/health_home_screen.dart (2 hunks)
  • frontend/ongi/lib/screens/health/pill_history_screen.dart (9 hunks)
  • frontend/ongi/lib/screens/home/home_degree_graph.dart (2 hunks)
  • frontend/ongi/lib/screens/home/home_donutCapsule.dart (10 hunks)
  • frontend/ongi/lib/screens/photo/detail_record_screen.dart (2 hunks)

Note

🎁 Summarized by CodeRabbit Free

Your organization is on the Free plan. CodeRabbit will generate a high-level summary and a walkthrough for each pull request. For a comprehensive line-by-line review, please upgrade your subscription to CodeRabbit Pro by visiting https://app.coderabbit.ai/login.

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Join our Discord community for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR/Issue comments)

Type @coderabbitai help to get the list of available commands.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Status, Documentation and Community

  • Visit our Status Page to check the current availability of CodeRabbit.
  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@taekoong taekoong merged commit 0b5ae98 into main Aug 18, 2025
3 of 4 checks passed
@taekoong taekoong deleted the fe/fix/develop branch August 25, 2025 20:36
Neibce pushed a commit to 2025-PNU-SW-Hackathon/PNUSW-2025-OnGi-10 that referenced this pull request Aug 25, 2025
* fix: 마음기록 입력 화면 뒤로가기 타화면과 통일

* fix: 온도그래프 수정

* fix: 온도그래프 수정

* fix: 약 사이드바 연결 지연 업그레이드

* fix: 온도그래프 오류 수정

* fix: 온도그래프 오류 수정

* fix: 오류 수정

* feat: 자녀화면 건강기록 세부

* feat: 자녀화면 사이드바 구현
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant